package com.ls.pattern.decorator.demo;

import java.util.List;

public abstract class PriceCalculateDecorator implements PriceCalculate {

    protected PriceCalculate priceCalculate;

    public PriceCalculateDecorator(PriceCalculate priceCalculate) {
        this.priceCalculate = priceCalculate;
    }

    @Override
    public Long calculatePrice(List<Product> products) {
        return this.discountPrice(products);
    }

    public abstract Long discountPrice(List<Product> products);
    
}
